package net.xdclass.rbac_shiro.dao;

import net.xdclass.rbac_shiro.domain.User;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

public interface UserMapper {

    @Select("select * from user where username = #{username}")
    User findByUsername(@Param("username") String username);


    @Select("select * from user where username = #{userId}")
    User findById(@Param("userId") int id);

    @Select("select * from user where username = #{userId} and password = #{pwd}")
    User findByUsernamePassword(@Param("userId") String username, @Param("pwd") String pwd);

}
